package test

import config.MyFile

object test extends MyFile{
  def main(args: Array[String]): Unit = {

    val gff = "D:\\黄瓜喝南瓜信息数据库开发\\黄瓜和南瓜信息数据库开发\\2021.5.12相关数据/Gy14_v2.gene.gff".readLines

    gff.filter(!_.startsWith("#")).filter(_.split("\t")(2) == "gene").map{line=>
      val lines = line.split("\t")

      val last =  lines.last.split(";")
      val geneId =  last.head.drop(3)
      val note = last.last.drop(5)
      val chr = lines.head
      val start = lines(3)
      val end = lines(4)
      val strand = lines(6)
      (0,geneId,chr,start,end,strand,note)
    }


  }
}
